import Router from '@koa/router';
import DashboardController from '@/controllers/DashboardController';
import { auth } from '@/middlewares';

const router = new Router({
  prefix: '/api/dashboard',
});

/**
 * 仪表盘路由
 */

// 获取仪表盘统计数据
router.get('/stats', auth, DashboardController.getStats.bind(DashboardController));

// 获取登录趋势数据
router.get('/login-trend', auth, DashboardController.getLoginTrend.bind(DashboardController));

// 获取服务器状态
router.get('/server-status', auth, DashboardController.getServerStatus.bind(DashboardController));

export default router;

